The small computer systems interface (SCSI) is defined by the American National Standard Information (ANSI) committee as a standard communications bus that includes specifications for electrical, mechanical and logical interfaces. SCSI provides for one SCSI address per device per data line on the bus. Accordingly, narrow SCSI provides for the connection of up to eight devices on the bus, each having a unique identification number (ID) or address from zero to seven. Therefore, a typical SCSI bus with one ID reserved for the host computer can support up to seven additional devices. These devices can be of any type, such as but not limited to disk drives, tape drives, optical storage devices, printers, scanners, etc.
ANSI document numbers X3.131-1986 and X3T9.2 (Global Engineering Documents, Irvine, Calif.) describe the electrical, mechanical and logical protocol specifications for SCSI related to this invention. These documents are incorporated herein by reference.
SCSI has become an industry standard for interfaces found on most higher end personal computers and workstations. It has become the standard for peripherals, such as disk drives, tape drives, optical storage devices, printers, scanners, etc. Like all standards, SCSI is used in a large number of installed pieces of computer equipment, which has resulted in a wide variety of SCSI products. Users have invested considerable money in computers and peripherals which employ the SCSI standard. However, developers of SCSI products are reaching the limits of the SCSI bus capabilities.
With the constant increase in the performance/price ratio of computer systems, the amount of data and the number of peripherals that need to be accommodated by the SCSI bus has increased. The problem with this increase is that normal 8 bit SCSI, without the use of LUN's, can only accommodate eight devices. There are many applications where more than eight devices are needed or desired. To get around the limitations of SCSI, the conventional solutions have been to add a repeater for distance and to make a custom SCSI device with a number of peripherals inside of it.
FIG. 1 shows a block diagram of a conventional SCSI system. Referring now to FIG. 1, a host computer (also called an initiator) 102 has been arbitrarily assigned SCSI ID No. 7. The addresses shown are arbitrary but must be unique for each device and must be less than or equal to the number of data bits on the bus. The SCSI specifications cover 8, 16 and 32 bit buses. The examples described herein are based on the eight bit SCSI bus, but can be applied to wider SCSI buses as well.
The host computer 102 is electrically connected to a SCSI bus 104. Connected to SCSI bus 104 are seven additional devices (also called targets) 106, 108, 110, 112, 114, 116 and 118. These additional (target) devices 106-118 can be any device that complies with the SCSI standard protocol. Additional device 106 has been assigned, for example, SCSI ID No. 0. Similarly, drive 108 has been assigned SCSI ID No. 1, drive 110 has been assigned SCSI ID No. 2, robotics 112 has been assigned SCSI ID No. 3, drive 114 has been assigned SCSI ID No. 4, drive 116 has been assigned SCSI ID No. 5, and robotics 118 has been assigned SCSI ID No. 6.
As an aside, it should be noted that drive 108, drive 110, and robotics 112 are shown as residing in an optical library enclosure 120. This is merely for purposes of illustration to show that more than one device connected to a SCSI bus can reside in a single physical enclosure. This inclusion of more than one SCSI device in a single physical (mechanical) enclosure is done, for example, in connection with the storage of large amounts of data.
Another conventional concept is also illustrated in FIG. 1. The length of the SCSI bus is limited in order to achieve desired electrical performances. For example, the SCSI bus cannot be more than six meters long (3 meters for fast) when a Single Ended bus is used. When a Differential bus is used, the SCSI bus can have a maximum length of 25 meters.
There are many situations where the additional device is located more than six meters, or more than 25 meters, (depending on the communication scheme employed) from the host computer 102. This is graphically illustrated in FIG. 1. It is seen that a conventional repeater 124 connects additional device 106 via a SCSI bus 2 (assigned reference number 126) to the main SCSI bus 104. Repeater 124 provides the necessary signal buffering to allow for the additional device 106 to be physically situated more than the six meter or 25 meter limit from the host computer 102.
Repeater 124 merely acts to boost the signal strength received on one bus back to the desired signal strength for the other bus. The repeater 124 preforms this amplification in both directions depending on which direction the specific SCSI signal is headed. The repeater 124 does nothing more than buffer and amplify the SCSI bus signals so as to allow for a longer distance for the entire cable. In effect, it acts like repeaters used in many other applications such as telephones and radios in terms of merely amplifying the signal levels from one bus to a second bus. It should be noted that no signal storage or mapping or other function occurs in repeater 124. The repeater 124 does not modify or redirect the information passed through it.
As stated above, there are many situations where it is needed or desired to have more than eight devices connected to a SCSI bus.
One conventional approach for allowing for more than eight units to be effectively connected to the SCSI bus is shown in FIG. 2. The SCSI bus 104 is connected to a peripheral device 202. Peripheral device 202 is assigned a single SCSI ID number. As far as the SCSI bus 104 is concerned, peripheral device 202 has a single SCSI identification.
Peripheral device 202 includes a plurality of N drives, for example, (where N is a positive integer greater than 1). Specifically, in the examples shown, peripheral device 202 includes a drive 1 (labeled with reference number 218), a drive 2 (labeled with reference number 224), and a drive N (labeled with reference number 230). A controller 204 electrically connects the SCSI bus 104 with the drives 218, 224 and 230 using a hard-wired, (often proprietary), and dedicated approach as follows.
As shown, controller 204 includes a microprocessor 206, switching electronics 208, a stored computer program 210, and electronic storage 212 for use by the controller 204 and microprocessor 206. Together, controller 204 routes information received from the SCSI bus 104 to the specific drive 218, 224, 230 as determined by the program stored in program 210 of controller 204. This routing is accomplished using individual buses and control lines for each of the drives. For example, as shown, drive 218 is connected to the controller 204 via a bus 214. In addition, a control line 216 is included, which allows controller 204 to control the operation of drive 218. Similarly, drive 224 includes a bus 220 and a control line 222, and drive 230 includes a bus 226 and a control line 228. It can be seen that this approach requires specific buses and control lines for the controller 204 in order to effect a desired data transfer.
Controller 204 must be programmed using its stored computer program 210 so as to be able to carry out the intended functions that are needed to accommodate the SCSI bus 104. It can be appreciated that the drives 218, 224 and 230 cannot be directly connected to the SCSI bus 104. Similarly, it can be appreciated that the controller 204 is required in order to accommodate the interfacing between the SCSI bus 104 and the drives 218, 224 and 230. Typically, controller 204 is required to reformat data received from SCSI bus 104 for transmission to one or more of the drives 218, 224 and 230, and for transmission on the SCSI bus 104. Therefore, it can also be appreciated that considerable data reformatting and SCSI bus protocol accommodation must be made by the peripheral device 202. Nevertheless, peripheral device 202 provides a means to connect more than one device to SCSI bus 104 at a single address.
The SCSI standard further includes a logical unit number (LUN). A logical unit number is specified from 0 to 7. Some host computers 102 include drivers (hardware and/or software) which provide the logical unit number, whereas others have more simple drivers that do not provide the logical unit number. Modification of the host computer to include such a driver is relatively simple and inexpensive and is conventionally known.
The provision of a logical unit number by the host computer 102 on the SCSI bus 104 allows for a peripheral device 202 to specify up to eight devices contained in the peripheral device 202. In other words, the logical unit number allows the peripheral device 202 to select a desired internal device that is being specified by the SCSI bus 104. Thus, up to eight devices can be contained in a peripheral device 202 having a controller 204 which can recognize and operate using a logical unit number provided on the SCSI bus 104.
Conventional approaches required that the controller 204 recognize the logical unit number, then act to control the internal devices 218, 224 through 230, and to remap data sent to and received from devices 218, 224 through 230 via the controller 204. This typically requires that the devices 218, 224 and 230 be dedicated. It also requires considerable additional electronics to accommodate the logical unit function specified on the SCSI bus 104. Nevertheless, it can be seen that this results in a single SCSI ID number being able to accommodate up to eight internal devices as specified by the logical unit number.
It should be noted that although this solution does add devices to the SCSI bus 104 using the LUN mode and the local devices 218, 224 through 230 can be SCSI devices, this approach of using a computer system for control does not meet the timing specifications for the SCSI bus 104. The local signals do not connect directly or through a simple buffer to the host SCSI bus 104. The controller 204 must receive and then retransmit all information bytes between the SCSI bus 104 and the local devices 218, 224 through 230.
Conventional approaches exhibit significant deficiencies. Where the logical unit number is not used, it can be seen that the number of devices that can be accommodated on the SCSI bus 104 is a maximum of eight.
Where the logical unit number is employed, it can be seen that the maximum number of logical unit numbers of devices that can be accommodated on the SCSI bus 104 is fifty-six (7 SCSI ID numbers.times.8 logical units, where the first SCSI ID number is assigned to the host computer 102). However, considerable electronics is required to accommodate the additional devices that are assigned to a specific SCSI ID number. In addition, these devices typically have to be dedicated, and do not use the SCSI bus interface between their controller 204 and the device 218, 224 through 230. Reformatting and control signaling is required, and existing devices merely have SCSI interfaces, but cannot be connected to the controller 204 or used in such a configuration.
U.S. Pat. No. 5,239,632 entitled "DEVICE TO TRANSLATE LOGICAL UNIT NUMBER COMMUNICATIONS ON ONE SCSI BUS TO ID COMMUNICATIONS ON A SUBORDINATE SCSI BUS", incorporated herein by reference, solved many of the problems of the prior art by use of a SCSI LUN converter utilizing state machines and transfer gates to bridge between a main SCSI bus and a subordinate SCSI bus supporting additional devices, as shown in FIGS. 3 and 4.
Referring now to FIG. 3, host computer 102 provides SCSI ID numbers and logic unit numbers in accordance with SCSI protocol. Host computer 102 is assigned SCSI ID number 7. It should be noted that the host computer 102 must include a driver which can provide the logic unit numbers (LUN). Host computer 102 can be any computer system using a SCSI bus. Host computer 102 is connected to the SCSI bus 104, labeled "master" SCSI bus. Connected to master SCSI bus 104 are additional devices 106, 108, 110, 112 and 114. These additional devices are assigned master SCSI ID numbers 0, 1, 2, 3 and 4, respectively.
Master SCSI ID number 6 is connected to the master SCSI bus 104 by a device called a Minnow 304. Minnow 304 is assigned master SCSI ID number 6. Minnow 304 is associated with the eight additional devices that are associated with master SCSI ID number 6. This association is indicated by the dashed-line box 302. It should be noted that the additional devices associated with master SCSI ID number 6 do not have to be physically located in the same mechanical enclosure, or at the same location, but merely need to be physically distant from Minnow 304 within the length (6 meters or 25 meters) of the communications approach in accordance with the SCSI protocol that is used, assuming no repeaters are associated with master SCSI ID number 6.
The eight additional devices that are associated with master SCSI ID number 6 are connected to the Minnow 304 by a "subordinate" SCSI bus 306, which utilizes the standard SCSI protocol. Thus, it can be appreciated, that the additional devices connected to the subordinate SCSI bus 306 can be ones that use the conventional SCSI protocol, and do not have to be modified or enhanced in any way.
Representative examples of additional devices that can be connected to the subordinate SCSI bus 306 are a printer 308, assigned subordinate SCSI ID number 0; a scanner 310, assigned subordinate SCSI ID number 1; a tape drive 312, assigned subordinate SCSI ID number 2; an optical storage device 314, assigned subordinate SCSI ID number 3; and a modem, assigned subordinate SCSI ID number 7.
A Minnow 304', included in the physical enclosure 320 is the same as Minnow 304, except for the fact that it responds to master SCSI ID number 5 and supports a different set of additional devices 324, 326 and 328 by means of subordinate SCSI bus 322.
Minnow 304 and Minnow 304' each map communications provided on the master SCSI bus 104 for their particular master SCSI ID number to the appropriate device on the associated subordinate SCSI bus 306 or 322, respectively using SCSI LUN numbers.
Specifically, host computer 102 provides a master SCSI ID number and a logical unit number as part of its standard SCSI protocol. The Minnow 304 responds to its master SCSI ID number 6. It maps communications to the devices connected to its subordinate SCSI bus 306 in accordance with the logical unit numbers that are supplied by the host computer 102. Only one master SCSI ID number is used for the master SCSI bus 104. However, through the use of the logical unit numbers associated with that master SCSI ID number, the Minnow 304 is able to connect up to eight additional devices to the host computer 102 through the use of its mapping function and its subordinate SCSI bus 306. None of the additional devices connected to its subordinate SCSI bus 306 have to be modified since the mapping of the logical unit numbers from the master SCSI bus 104 are converted to subordinate SCSI ID numbers for the subordinate SCSI bus 306. Thus, Minnow 304 bridges the master SCSI bus 104 with its subordinate SCSI bus 306.
There are two types of SCSI arbitrations, Select and Reselect. Select arbitrations are performed by the host computer when selecting a target device. Select arbitrations start a SCSI command. All commands are initiated by the host computer 102. Some commands can take a significant amount of time for a device to complete, in which case the target device can inform the host computer 102 that it will be busy for awhile after which the target device can put the communication on hold. During this time the host computer 102 or any other SCSI device can use the SCSI bus. Once a target device is ready to respond to the command it had previously put the host computer 102 on hold for, the target can Reselect the host computer 102 and finish the command. The signals used in arbitration are BSY, SEL, ATN, IO, and the data lines. One data line is used for each SCSI address with data line 0 being SCSI address 0, data line 1 being SCSI address 1, etc.
When a SCSI device is ready to arbitrate, it waits for the SCSI bus to be free. The bus free condition is when neither BSY and SEL is asserted. Once the bus is free, the SCSI device asserts BSY and its address on the bus. During this part of the arbitration, any other device can also assert BSY and its address. After all devices have had a chance to join in, the winning device is determined. This is based on the highest address asserted. The winning device then asserts SEL and then waits for all other devices to get off of the bus. The winning device then asserts the address of the device it wants to talk to and either ATN or IO. If the winning device is the host computer 102 performing a Select, it asserts ATN. If the winning device is a target device performing a Reselect, it asserts IO. In either case, the winning device then releases BSY. The device being Selected or Reselected by the winning device asserts BSY. For a Select operation, the winning device (host computer 102) releases SEL and the two devices enter the SCSI information transfer phase. For a Reselect operation, the winning device reasserts BSY and then releases SEL. The Reselected device (host computer 102) then releases its busy signal and the two devices enter the information transfer phase.
It should be noted that the device which started the arbitration cycle may not be the winning device. In the case of a LUN or repeater card, the device which started may be on a different bus. As a result, the direction of the BSY line may change multiple times during the initial arbitration sequence. In repeaters and LUN boards, this turning around of the BSY line causes glitches on the line because the repeater and LUN board arbitration logic has to detect and respond to the change in direction of the BSY line. It takes a small but detectable amount of time for this to occur.
There are six phases defined for SCSI information transfer; "Message In", "Message Out", "Command", "Status", "Data In", and "Data Out". The target device controls which phase the bus is in by controlling the state of the MSG, IO, and CD SCSI lines. The host computer 102 asserts the ATN line when it needs to notify the target device of something (usually some sort of error condition). A normal SCSI information transfer starts with an identify message followed by other messages and then a command, data, status, and a command complete message. As noted above, if the command cannot be done immediately, the target device may go bus free after the command only to Reselect the host computer 102 later and then finish the command.
During the message phase after the identify message and before the command phase, the target device and the host computer 102 setup data communication modes amongst other things. There are three types of SCSI communication modes: asynchronous, synchronous (200 nsec.), and fast synchronous (100 nsec.). This data communication mode setup is normally done the first time a host computer 102 and a target device communicate after a SCSI bus reset. The communication mode persists through all arbitration cycles unless renegotiated on. The communications mode only effects the data transfer phases. All other communication phases are asynchronous only.
As used herein, the Select cycle and the Reselect cycle are in accordance with those cycles as used in the SCSI protocol. There has been no modification in any way to the SCSI protocol with regard to the Select cycle or the Reselect cycle, or with respect to anything else described herein.
In the Select cycle the host computer (initiator) 102 selects the Minnow 304 by sending its master SCSI ID number out on the master SCSI bus 104. The Minnow 304 responds to its master bus SCSI ID number and retrieves the logical unit number from the "Identify Message Out" that is then sent by the host computer 102. According to SCSI protocol, this step established communication in the Select cycle between the host computer 102 and the Minnow 304. As far as the host computer 102 is concerned, the Minnow 304 that is selected using the master SCSI ID number is the target device.
The Minnow then converts the logical unit number from the "Identify Message Out" to the subordinate SCSI ID number of the specified target on the subordinate SCSI bus 306. Then the Minnow 304 communicates with the target using the subordinate SCSI ID number of the target. The target device responds. And the Minnow 304 then send the "Identify Message Out" to the target via the subordinate SCSI bus 306. This step establishes communications between the Minnow 304 and the target device as specified by the logical unit number received from the host computer 102.
In the final step of the Select cycle, the Minnow 304 connects the master SCSI bus 104 to the subordinate SCSI bus 306 so that the host computer 102 can communicate with the target device on the subordinate SCSI bus 306. This communication from the host computer 102 to the target device on subordinate SCSI bus 306 and vice versa appears to each side to be direct. In fact, transceivers are utilized in Minnow 304 so that transfer of data between the master SCSI bus 104 and the subordinate SCSI bus 306 can be accomplished.
SCSI protocol also includes a Reselect cycle, which allows a target device to work on a task and not tie up the SCSI bus while it is working on this task. In other words, the target device once assigned a task in the Select cycle, can get off the master and subordinate SCSI buses and work on the specified task. When the target device has reached the point in the specified task where it is ready to send data back out on the master and/or subordinate SCSI buses, it initiates the Reselect cycle. In this way, optimal utilization of the master and subordinate SCSI buses occurs.
In the Reselect cycle, the target device Reselects the Minnow 304 by sending its SCSI ID out on the subordinate SCSI bus 306. Minnow 304 responds to its master bus SCSI ID number and retrieves the logical unit number from the "Identify Message In" that is sent by the target. This step establishes communications in the Reselect cycle between the target device and the Minnow 304. As far as the target device is concerned, the Minnow 304 that is Reselected is the host computer 102.
In a final step of the Reselect cycle, Minnow 304 connects the master SCSI bus 104 to the subordinate SCSI bus 306 so that the host computer 102 can communicate with the target device on the subordinate SCSI bus 306. This communication from the host computer 102 to the target device on the subordinate SCSI bus 306 and vice versa appears to each side to be direct. In fact, transceivers are utilized in the Minnow 304 so that the transfer of data between the master SCSI bus 104 and the subordinate SCSI bus 306 can be accomplished.
Referring now to FIG. 4, the master SCSI bus 104 is connected to a master selection machine 402, a master reselection machine 404, and transceivers 406. Master selection machine 402 is connected to an ID switch 406, as is the master reselection machine 404. The ID switch 406 can be set by the user to specify the master SCSI ID number for the master SCSI bus 104 that the Minnow 304 is set to respond to.
Master selection machine 402 responds to the master SCSI ID number sent on the master SCSI bus 104, and then retrieves the logical unit number from the "Identify Message Out" received from the master SCSI bus 104. The master selection machine 402 converts the logical unit number to the subordinate SCSI ID number of the specified target device on the subordinate SCSI bus 306. This subordinate SCSI ID number is supplied via a line 408 to a subordinate selection machine 410.
The subordinate selection machine 410 is connected to the subordinate SCSI bus 306. Similarly, a subordinate reselection machine 440 is connected to the subordinate SCSI bus 306. In addition, the transceivers 406 are connected to the subordinate SCSI bus 306.
A main control machine 412 communicates master selection machine control signals 414 to/from the master selection machine 402, communicates master reselection machine control signals 416 to/from the master reselection machine 404, communicates transceiver control signals 418 to/from the transceivers 406, communicates subordinate selection machine control signals 420 to/from the subordinate selection machine 410, and communicates subordinate reselection machine control signals 422 to/from the subordinate reselection machine 440. The main control machine 412 acts to control the operation of the five devices (state machines 402, 404, 410, 440 and transceivers 406) that it is connected to in Minnow 304. Control is in accordance with the Selection and Reselection cycles as discussed above.
The subordinate selection machine 410 communicates with the target via the subordinate SCSI bus 306. The target is identified by the subordinate SCSI ID number received on line 408. It is the subordinate selection machine 410 that sends the "Identify Message Out" to the target on the subordinate SCSI bus 306.
Thereafter, the main control state machine 412 communicates with the transceivers 406 so that proper transfer of data on master SCSI bus 104 and data on subordinate SCSI bus 306 takes place so that the host computer and the target device believe that they are in direct communications with each other.
In the Reselection cycle, the subordinate reselection machine 440 respond to the Reselection and "Identify Message In" received from the target device on the subordinate SCSI bus 306. The subordinate reselection machine 440 responds and retrieves the subordinate bus SCSI ID number from the "Identify Message In".
The subordinate reselection machine 440 converts the subordinate bus SCSI ID number to the logical unit number, which is also called the LUN info. The logical unit number (LUN Info) is provided via a line 424 to the master reselection machine 404.
The master reselection machine 404 reselects the host computer 102 on the master SCSI bus 104. Under control of the main control state machine 412, it reselects the host computer 102 then handshakes the "Identify Message In" to the host computer 102 connected to the master SCSI bus 104.
Thereafter, the main control machine 412 via transceiver control signal 418 uses the transceivers 406 to properly transfer data on the subordinate SCSI bus 306 to the master SCSI bus 104 and vice versa. In this way, the target and the initiator believe that they are in direct communications with each other.
Although this LUN converter solution does meet the specifications for the SCSI bus timing and connects the local target devices "directly" with the master SCSI bus 104 with the use of buffers used as switches to connect and disconnect signals, it is deficient in several critical areas. First, this solution does not address error conditions on the bus, such as when the host computer 102 tries to use a SCSI message which is not supported by LUN converter. There are many messages defined in SCSI, not all of which apply to all SCSI devices. Also, it is not mandatory for all SCSI devices to accept all SCSI messages. If the host computer 102 uses one of the messages that is not supported with the LUN converter, the LUN converter must be able to give the correct response back to the host computer 102. This LUN converter solution also does not handle communications from the host computer 102 directed at the LUN converter itself instead of a local target device such as device reset messages without the identify which imply resetting all LUN's within the target.
Second, there is no means provided in this solution to inform the host computer 102 that the requested target device is not available, which can cause the system to fail. The host computer 102 generally cannot tell which LUN's are valid without requesting the LUN in SCSI. The LUN card must establish communications with the host computer 102 before it can find out which LUN is being requested. If the host computer 102 requests an invalid LUN, the LUN converter must be able to give the correct response back to the host computer 102. Otherwise, the SCSI bus would fail and the system would stop running (system hang), which is what happens with this system.
Another area that this solution is deficient in is the actual data transfer operation after the target device has been selected. Specifically, SCSI allows for three modes of data transfer: asynchronous, synchronous and fast synchronous. These modes are not directly interchangeable. The solution of U.S. Pat No. 5,239,632 does not provide for the different communication modes. Accordingly, if the host computer 102 tries to communicate with a target device in asynchronous mode and the target device only communicates in synchronous mode, the system will fail, which means the computer system would hang or even worse, the data being transferred on SCSI could be changed randomly. Depending on what information was being transferred, this error could damage critical data.
Still further, implementations of this solution have problems with glitches on either the master or subordinate SCSI bus during arbitration. Basically, arbitration is when the host computer and local target devices decide who is going to use the bus. The SCSI bus arbitration sequence is an involved process and the complexity of multiple state machines used in this solution make it difficult to prevent glitches on either SCSI bus, which can cause the computer system to be unable to access a device and possibly hang.